﻿Imports System.Windows.Forms

Public Class FormFiltreTexte
    Private Sub OK_Button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OK_Button.Click
        Me.DialogResult = System.Windows.Forms.DialogResult.OK
        Me.Close()
    End Sub

    Private Sub Cancel_Button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Cancel_Button.Click
        Me.DialogResult = System.Windows.Forms.DialogResult.Cancel
        Me.Close()
    End Sub

    Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        Dim oTrans As New ClassTextOp
        oTrans.Operation = ClassTextOp.EnumTextOperation.RemplacerTexte
        oTrans.Parametres(0) = Me.TextBox1.Text
        oTrans.Parametres(1) = Me.TextBox2.Text
        oTrans.Parametres(2) = Me.CheckBox1.Checked.ToString
        Me.RichTextBoxResult.Text = oTrans.Transformer(Me.RichTextBox1.Text)
        oTrans = Nothing
    End Sub

End Class
